#include <iostream>
#include <cstdio>
#include <cstdlib>
#include <queue>
#include <stack>
#include <algorithm>
#include <string>
#include <map>
#include <set>
#include <vector>

using namespace std;

#define BEGINS(x) namespace x {
#define ENDS(x) } // end of namespace x

class BigInt : public vector<int> {
public:
    BigInt() = default;
    BigInt(int x) {
        push_back(x);
        process_digit();
    }
    BigInt operator+(const BigInt &bi) {
        BigInt tmp;
        if (this->size() >= bi.size()) {
            tmp = *this;
            for (int i = 0; i < size(); i++) {
                tmp.at(i) += bi.at(i);
            }
        } else {
            tmp = bi;
            for (int i = 0; i < size(); i++) {
                tmp.at(i) += this->at(i);
            }
        }
        tmp.process_digit();
        return tmp;
    }
    friend ostream &operator<<(ostream &out, const BigInt &bi) {
        for (int i = bi.size() - 1; i >= 0; i--) {
            out << bi.at(i);
        }
        return out;
    }
private:
    void process_digit() {
        for (int i = 0; i < size(); i++) {
            if (at(i) < 10) continue;
            if (i + 1 == size()) push_back(0);
            at(i + 1) += at(i) / 10;
            at(i) %= 10;
        }
        while (size() > 1 && at(size() - 1) == 0) {
            pop_back();
        }
    }
};

int main() {
    // BigInt a(1);
    // BigInt b(12);
    // cout << (a + b) << endl;
    // cout << a << endl;
    // cout << b << endl;
    int m;
    cin >> m;
    BigInt a[505] = {0};
    a[1] = 1;
    a[2] = 2;

    for (int i = 3; i <= m; i++) {
        a[i] = a[i - 2] + a[i - 1];
    }
    cout << a[m] << endl;

    return 0;
}
//9010910435053616553
//4859788740867454402